package cn.com.blueInfo.bpm.system.entity;

import cn.com.blueInfo.bpm.common.entity.BaseEntity;
import cn.com.blueInfo.bpm.system.enums.ResourceType;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import lombok.EqualsAndHashCode;

/**
 * 资源表
 * @author suxch
 * @since 2025-08-24 01:37:55
 */
@Data
@EqualsAndHashCode(callSuper = true)
@TableName(value = "mc_sys_resource", autoResultMap = true)
@Schema(description = "资源表")
public class Resource extends BaseEntity {

    /** ID */
    @TableId(type = IdType.INPUT)
    @Schema(description = "ID")
    private Long id;
    /** 资源名称（如“用户新增按钮”等） */
    @Schema(description = "资源名称（如“用户新增按钮”等）")
    private String resourceName;
    /** 资源类型：1-菜单，2-按钮，3-字段 */
    @Schema(description = "资源类型：1-菜单，2-按钮，3-字段")
    private ResourceType resourceType;
    /** 权限标识（如“sys:user:add”） */
    @Schema(description = "权限标识（如“sys:user:add”）")
    private String permissionKey;
    /** 菜单ID */
    @Schema(description = "菜单ID")
    private Long menuId;

}
